<?php
namespace Home\Controller;

class IndexController extends CommonController {
    public function index($type=0){
        $map = array('status'=>array('neq', '0'),'type_id'=>$type);
        $projects = M('project')->where($map)->select();
        $types = M('project_type')->where(array('status'=>1))->select();
        $this->assign('projects',$projects);
        $this->assign('types',$types);
        $this->assign('type',$type);
        $this->assign('meta_title','项目大厅');
        $this->assign('mark','index');
        $this->display();
    }
}
